! function(w){//加载更多插件
	// IE的文档模式永远都是最新的  头部加下面代码
	//<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
	"use strict";
	var doc=document;
	if(w._hcinits==undefined){console.log('_video.js load _hcinits fail');}
	var _h=w._hcinits;
	_h._video={
		DivIdObjArr:{},
		videoClassObj:null,
		videonode:null,//video 节点
		mouseflag:false,
		durationmouseflag:false,
		videonumber:0,
		curvolume:{},
		fullscreenstyle:{},
		config:{
			divId:'addvideo_id',//放置video的对象id
			videoId:'hcinit_video_id',//video标签的id
			videoWidth:'100%',
			videoHeight:'100%',
			videoPoster:'/p1.jpg',
			sourceId:'hcinit_video_source_id',//source标签id
			sourceSrc:'/test.mp4',//source标签src
			sourceType:'video/mp4',//source标签type
			play:false,
			controls:false,//是否显示默认控制条 
			loop:false,//重新播放
		},
		init:function(config){
			var t=this;
			for(var k in config){t.config[k] = config[k];}
			t.videonode=doc.createElement('video');
			t.videonode.className ='hcinit_video_init_js';
			t.videonode.id=t.config.videoId;
			t.videonode.poster=t.config.videoPoster;
			t.videonode.preload="auto";
			var sourcenode=doc.createElement('source');
			sourcenode.id=t.config.sourceId;
			sourcenode.src=t.config.sourceSrc;
			sourcenode.type=t.config.sourceType;
			t.videonode.appendChild(sourcenode);
			var divIdObj=doc.getElementById(t.config.divId);
			var divlen=Object.keys(t.DivIdObjArr).length;
			t.DivIdObjArr[divlen]=divIdObj;
			divIdObj.appendChild(t.videonode);
			var novideomessage=doc.createElement('p');
			novideomessage.className='novideomessage';
			novideomessage.innerHTML='<p>不支持video html </p>';
			t.videonode.appendChild(novideomessage);
			//videoId 
			t.videoIdObj=doc.getElementById(t.config.videoId);
			//获取video的个数
			t.videoClassObj=doc.getElementsByClassName('hcinit_video_init_js');
			t.videonumber=t.videoClassObj.length;
			var isie=_h.device().broswer=='IE'?true:false;
			//进度条
			if(this.config.controls===true || isie==true ){//当前设置默认video ie默认video视频播放
				t.videoIdObj.controls=true;
			}else if(isie==true){
				t.videoIdObj.controls=true;
			}else{
				//获取控件html内容
				t.getControlhtml(divIdObj);
				for(var curnumber=0;curnumber<t.videonumber;curnumber++){
					//控制台
					t.onmousemoveshowhide(curnumber);
					//1.加载完成可以播放调用 主要用户获取视频总长    2.视频内容播放改变调用  3.鼠标选中搜索取消
					t.getdurationinfo(curnumber);
					//播放进度条 点击 和 拖动事件
					t.getVideoProgressBar(curnumber);
					//开始按钮
					t.startPlay(curnumber);
					//重新加载
					t.reLoad(curnumber);
					//倍数
					t.getPlaybackRate(curnumber);
					//声音|静音
					t.getvolume(curnumber);
					//大屏
					t.getfullscreen(curnumber);
					//
					t.reLoop();
				}
			}
			doc.ondragstart=function(ev){
				return false;//防止选择 跳入百度搜索
			}
	     	doc.onmouseup=function(ev){
				t.mouseflag=false;
				t.durationmouseflag=false;
			}
			return t;
		},
		onmousemoveshowhide:function(curnumber){
			var t=this;
			t.videoClassObj[curnumber].controls=false;
			t.videoClassObj[curnumber].setAttribute('x5-playsinline','');
			t.videoClassObj[curnumber].setAttribute('playsinline','');
			t.videoClassObj[curnumber].setAttribute('webkit-playsinline','');
			t.videoClassObj[curnumber].setAttribute('x-webkit-airplay','');
			t.videoClassObj[curnumber].setAttribute('x5-video-player-type','h5');
			t.videoClassObj[curnumber].setAttribute('x5-video-player-fullscreen',true);
			t.videoClassObj[curnumber].style.width=t.config.videoWidth;
			t.videoClassObj[curnumber].style.height=t.config.videoHeight;
			doc.getElementsByClassName('hcinit_video_init_js')[curnumber].onmousemove=function(){
				doc.getElementsByClassName('hcinit_control_head')[curnumber].style.display='block';
			}
			doc.getElementsByClassName('hcinit_control_head')[curnumber].onmousemove=function(){
				doc.getElementsByClassName('hcinit_control_head')[curnumber].style.display='block';
			}
			doc.getElementsByClassName('hcinit_control_head')[curnumber].onmouseout=function(){
			//	doc.getElementsByClassName('hcinit_control_head')[curnumber].style.display='none';
			}
		},
		getfullscreen:function(curnumber){
			var t=this,ele=t.DivIdObjArr[curnumber];
			doc.getElementsByClassName('hcinit_video_controls_fullscreen')[curnumber].onclick=function(){
				var isFull =doc.isFullScreen || doc.mozIsFullScreen || doc.webkitIsFullScreen;
　　　　		if(isFull === undefined){isFull = false;}
				if(isFull===false){//全屏
					 if(ele.requestFullscreen){
						 ele.requestFullscreen();
					 }else if(ele.mozRequestFullScreen){
						 ele.mozRequestFullScreen();
					 }else if(ele.msRequestFullscreen){
						 ele.msRequestFullscreen();
					 }else if(ele.oRequestFullscreen){
						 ele.oRequestFullscreen();
					 }else if(ele.webkitRequestFullscreen){
						 ele.webkitRequestFullscreen();
					 }else{
						 alert('当前浏览器,不支持全屏');
						 return false;
					 }
					 t.fullscreenstyle['curnumber']=curnumber;
					 t.fullscreenstyle['width']=ele.style.width;
					 t.fullscreenstyle['height']=ele.style.height;
					 ele.style.width='100%';
					 ele.style.height='100%';
					 doc.getElementsByClassName('hcinit_control_head')[curnumber].style.zIndex=3147483647;

				}else{//退出全屏
					if(doc.exitFullscreen){
						doc.exitFullscreen();
					}else if(doc.msExitFullscreen){
						doc.msExitFullscreen();
					}else if(doc.mozCancelFullScreen){
						doc.mozCancelFullScreen();
					}else if(doc.oRequestFullscreen){
						doc.oCancelFullScreen();
					}else if(doc.webkitExitFullscreen){
						doc.webkitExitFullscreen();
					}
					ele.style.width=t.fullscreenstyle['width'];
					ele.style.height=t.fullscreenstyle['height'];
					t.fullscreenstyle['curnumber']='';
					t.fullscreenstyle['width']='';
					t.fullscreenstyle['height']='';
				}
			}
		},
		getvolume:function(curnumber){
			var t=this;
			doc.getElementsByClassName('hcinit_video_controls_volume')[curnumber].onclick=function(ev){
				var isvolumelength=doc.getElementsByClassName('hcinit_video_controls_volume_button')[curnumber].getElementsByClassName('volume').length;
				if(isvolumelength==1){//是正常声音
					//设置静音图标
					doc.getElementsByClassName('hcinit_video_controls_volume')[curnumber].classList.remove('volume');
					doc.getElementsByClassName('hcinit_video_controls_volume')[curnumber].classList.add('muted');
					doc.getElementsByClassName('hcinit_video_controls_volume_value')[curnumber].style.height="0px";
					doc.getElementsByClassName('hcinit_video_controls_volume_current_top')[curnumber].style.top='100px';
					t.curvolume[curnumber]=t.videoClassObj[curnumber].volume;
					t.setmuted(curnumber);
				}else{
					//取消静音图片
					doc.getElementsByClassName('hcinit_video_controls_volume')[curnumber].classList.remove('muted');
					doc.getElementsByClassName('hcinit_video_controls_volume')[curnumber].classList.add('volume');
					var curvolume=t.curvolume[curnumber]!=undefined?t.curvolume[curnumber]:1;
					doc.getElementsByClassName('hcinit_video_controls_volume_value')[curnumber].style.height=(curvolume*100)+"px";

					doc.getElementsByClassName('hcinit_video_controls_volume_current_top')[curnumber].style.top=(100-(curvolume*100))+'px';
					t.videoClassObj[curnumber].volume=curvolume;
				}
			}
			doc.getElementsByClassName('hcinit_video_controls_volume_button')[curnumber].onmousemove=function(ev){
				var playbackrateobj=doc.getElementsByClassName('hcinit_video_controls_volume_bg')[curnumber];
				playbackrateobj.style.display='block';
				
			}
			
			doc.getElementsByClassName('hcinit_video_controls_volume_button')[curnumber].onmouseout=function(ev){
				
				var playbackrateobj=doc.getElementsByClassName('hcinit_video_controls_volume_bg')[curnumber];
				playbackrateobj.style.display='none';
			}
			doc.getElementsByClassName('hcinit_video_controls_volume_current')[curnumber].onclick=function(ev){
				t.mouseflag=false;
				var currentH=ev.offsetY;
				if(currentH<0){currentH=100+currentH;}//兼容浏览器ie 值为负值
				//设置最小剩余0；
				if(100-currentH<5){currentH=100;}
				//设置最大声音为95%;
				if(100-currentH>92){currentH=5;}
				t.videoClassObj[curnumber].volume=(100-currentH)/100;
				t.curvolume[curnumber]=currentH;
				var isvolumelength=doc.getElementsByClassName('hcinit_video_controls_volume_button')[curnumber].getElementsByClassName('muted').length;
				if(isvolumelength==1){//是正常声音
					doc.getElementsByClassName('hcinit_video_controls_volume')[curnumber].classList.remove('muted');
					doc.getElementsByClassName('hcinit_video_controls_volume')[curnumber].classList.add('volume');
				}
				doc.getElementsByClassName('hcinit_video_controls_volume_value')[curnumber].style.height=(100-currentH)+"px";
				doc.getElementsByClassName('hcinit_video_controls_volume_value')[curnumber].style.top =currentH+"px";
				doc.getElementsByClassName('hcinit_video_controls_volume_current_top')[curnumber].style.top=currentH+'px';
			}
			doc.getElementsByClassName('hcinit_video_controls_volume_current')[curnumber].onmousemove = function(ev){
				//var currentH=ev.layerY||ev.offsetY;
				var currentH=ev.offsetY;
				if(t.mouseflag===true){
					if(currentH<0){currentH=100+currentH;}//兼容浏览器ie 值为负值
					//设置最小剩余0；
					if(100-currentH<5){currentH=100;}
					//设置最大声音为95%;
					if(100-currentH>92){currentH=5;}
					t.videoClassObj[curnumber].volume=(100-currentH)/100;
					t.curvolume[curnumber]=currentH;
					var isvolumelength=doc.getElementsByClassName('hcinit_video_controls_volume_button')[curnumber].getElementsByClassName('muted').length;
					if(isvolumelength==1){//是正常声音
						doc.getElementsByClassName('hcinit_video_controls_volume')[curnumber].classList.remove('muted');
						doc.getElementsByClassName('hcinit_video_controls_volume')[curnumber].classList.add('volume');
					}

					doc.getElementsByClassName('hcinit_video_controls_volume_value')[curnumber].style.height=(100-currentH)+"px";
					doc.getElementsByClassName('hcinit_video_controls_volume_value')[curnumber].style.top =currentH+"px";
					doc.getElementsByClassName('hcinit_video_controls_volume_current_top')[curnumber].style.top=currentH+'px';
				}
	     	}
			doc.getElementsByClassName('hcinit_video_controls_volume_value')[curnumber].onclick=function(ev){
				t.mouseflag=false;
				var currentH=ev.offsetY;
				//console.log('ev.offsetY:'+ev.offsetY+";ev.layerY:"+ev.layerY);
				if(currentH<0){currentH=100+currentH;}//兼容浏览器ie 值为负值
				//设置最小剩余0；
				if(100-currentH<5){currentH=100;}
				//设置最大声音为95%;
				if(100-currentH>92){currentH=5;}
				t.videoClassObj[curnumber].volume=(100-currentH)/100;
				var isvolumelength=doc.getElementsByClassName('hcinit_video_controls_volume_button')[curnumber].getElementsByClassName('muted').length;
				if(isvolumelength==1){//是正常声音
					doc.getElementsByClassName('hcinit_video_controls_volume')[curnumber].classList.remove('muted');
					doc.getElementsByClassName('hcinit_video_controls_volume')[curnumber].classList.add('volume');
				}
				var oldtop=doc.getElementsByClassName('hcinit_video_controls_volume_value')[curnumber].style.top;
				if(oldtop==''){
					oldtop='0px';
				}
				oldtop=oldtop.replace('px','');
				oldtop=oldtop.replace(/\s*/g,"");
				oldtop=parseInt(oldtop);
				var max_top=currentH+oldtop;
				if(max_top>100){max_top=100;}
				if(max_top<0){max_top=0};
				t.curvolume[curnumber]=max_top;
				t.videoClassObj[curnumber].volume=(100-max_top)/100;
				doc.getElementsByClassName('hcinit_video_controls_volume_value')[curnumber].style.height=(100-currentH-oldtop)+"px";
				doc.getElementsByClassName('hcinit_video_controls_volume_value')[curnumber].style.top=(currentH+oldtop)+"px";
				doc.getElementsByClassName('hcinit_video_controls_volume_current_top')[curnumber].style.top=(currentH+oldtop)+'px';
			}
			doc.getElementsByClassName('hcinit_video_controls_volume_current_top')[curnumber].onmousedown=function(ev){
				t.mouseflag=true;
			}
			doc.getElementsByClassName('hcinit_video_controls_volume_value')[curnumber].onmousemove = function(ev){
				var currentH=ev.offsetY;
				if(t.mouseflag===true){
					if(currentH<0){currentH=100+currentH;}//兼容浏览器ie 值为负值
					//设置最小剩余0；
					if(100-currentH<5){currentH=100;}
					//设置最大声音为95%;
					if(100-currentH>92){currentH=5;}
					t.videoClassObj[curnumber].volume=(100-currentH)/100;
					var isvolumelength=doc.getElementsByClassName('hcinit_video_controls_volume_button')[curnumber].getElementsByClassName('muted').length;
					if(isvolumelength==1){//是正常声音
						doc.getElementsByClassName('hcinit_video_controls_volume')[curnumber].classList.remove('muted');
						doc.getElementsByClassName('hcinit_video_controls_volume')[curnumber].classList.add('volume');
					}
					var oldtop=doc.getElementsByClassName('hcinit_video_controls_volume_value')[curnumber].style.top;
					if(oldtop==''){oldtop='0px';}
					oldtop=oldtop.replace('px','');
					oldtop=oldtop.replace(/\s*/g,"");
					oldtop=parseInt(oldtop);
					var max_top=currentH+oldtop;
					if(max_top>100){max_top=100;}
					if(max_top<0){max_top=0};
					t.videoClassObj[curnumber].volume=(100-max_top)/100;
					doc.getElementsByClassName('hcinit_video_controls_volume_value')[curnumber].style.height=(100-currentH-oldtop)+"px";
					doc.getElementsByClassName('hcinit_video_controls_volume_value')[curnumber].style.top=(currentH+oldtop)+"px";
					doc.getElementsByClassName('hcinit_video_controls_volume_current_top')[curnumber].style.top=max_top+'px';
				}
	     	}
		},
		getPlaybackRate:function(curnumber){
			var t=this;
			doc.getElementsByClassName('hcinit_video_controls_playbackRate_button')[curnumber].onmousemove=function(){
				var playbackrateobj=doc.getElementsByClassName('hcinit_video_controls_playbackRate_value_select')[curnumber];
				playbackrateobj.style.display='block';
			}
			doc.getElementsByClassName('hcinit_video_controls_playbackRate_button')[curnumber].onclick=function(){
				var playbackrateobj=doc.getElementsByClassName('hcinit_video_controls_playbackRate_value_select')[curnumber];
				playbackrateobj.style.display='block';
			}

			doc.getElementsByClassName('hcinit_video_controls_playbackRate_button')[curnumber].onmouseout=function(){
				var playbackrateobj=doc.getElementsByClassName('hcinit_video_controls_playbackRate_value_select')[curnumber];
				playbackrateobj.style.display='none';
				//playbackrateobj.style.display='block';
			}

			var ratediv=doc.getElementsByClassName('hcinit_video_controls_playbackRate_value_select')[curnumber].getElementsByTagName('div');
			var ratelength=ratediv.length;
			var ri;
			for(ri=0;ri<ratelength;ri++){
				t.setplaybackRate(ri,ratediv[ri].innerHTML,curnumber);
			}
		},
		setplaybackRate:function(ratek,ratev,curnumber){
			var t=this;
			var rateobj=doc.getElementsByClassName('hcinit_video_controls_playbackRate_value_select')[curnumber].getElementsByTagName('div');
			rateobj[ratek].onclick=function(){
				t.videoClassObj[curnumber].playbackRate=ratev;
				var ri,rlen=rateobj.length;
				for(ri=0;ri<rlen;ri++){
					if(ratek==ri){
						doc.getElementsByClassName('hcinit_video_controls_playbackRate_value_select')[curnumber].getElementsByTagName('div')[ri].className='hcinit_video_controls_playbackRate_value_current';
					}else{
						doc.getElementsByClassName('hcinit_video_controls_playbackRate_value_select')[curnumber].getElementsByTagName('div')[ri].className='';
					}
				}
			}
		},
		getdurationinfo_return:function(curnumber){
			var t=this;
			var totalduration=t.videoClassObj[curnumber].duration;
			if(isNaN(totalduration)){
				totalduration=0;
			}
			var curduration=t.videoClassObj[curnumber].currentTime;
			var curdurationtime=t.getTimeToDate(curduration);
			var totladurationtime=t.getTimeToDate(totalduration);
			//进度条显示操作
			var curprocess=Math.floor((curduration/totalduration)*100);
			doc.getElementsByClassName('hcinit_video_durationcontrol_current')[curnumber].style.width=curprocess+"%";
			doc.getElementsByClassName('hcinit_video_durationcontrol_top')[curnumber].style.left=curprocess+'%';
			doc.getElementsByClassName('hcinit_video_contols_duration_value')[curnumber].innerHTML=curdurationtime+'/'+totladurationtime;
		},
		getdurationinfo:function(curnumber){
			var t=this;
			t.videoClassObj[curnumber].oncanplay=function(){//加载完成可以播放调用 主要用户获取视频总长
				t.getdurationinfo_return(curnumber);
				var clientheight_value;
				clientheight_value=(t.videoClassObj[curnumber].videoHeight*t.videoClassObj[curnumber].clientWidth/t.videoClassObj[curnumber].videoWidth);
				clientheight_value=Math.ceil(clientheight_value);
				if(clientheight_value>doc.body.clientheight){
					clientheight_value=doc.body.clientheight;
				}
				t.videoClassObj[curnumber].style.height=clientheight_value;
				
				t.DivIdObjArr[curnumber].style.height=clientheight_value;

				console.log("curnumber"+curnumber+":"+t.videoClassObj[curnumber].style.height);
			}
			t.videoClassObj[curnumber].ontimeupdate=function(){//视频内容播放改变调用
				t.getdurationinfo_return(curnumber);
			}
			t.videoClassObj[curnumber].oncontextmenu=function(){//鼠标选中搜索取消
				return false;
			}
		},
		setCurrentTime:function(w,totalw,curnumber){
			var t=this;
			var percentage=Math.floor((w/totalw)*100);
			var totalduration=t.videoClassObj[curnumber].duration;
			if(isNaN(totalduration)){
				return false;
			}
			var curtime=Math.floor((totalduration*percentage)/100);

			t.videoClassObj[curnumber].currentTime=curtime;
		},
		//播放进度条显示控件
		getVideoProgressBar:function(curnumber){
			var t=this;
			var duc_v=doc.getElementsByClassName('hcinit_video_durationcontrol_value');
			var duc=doc.getElementsByClassName('hcinit_video_durationcontrol');
			var duc_t=doc.getElementsByClassName('hcinit_video_durationcontrol_top');
			duc_v[curnumber].onclick=function(ev){
				var currentX=ev.layerX||ev.offsetX;
				var totalwidth=duc[curnumber].clientWidth;
				t.setCurrentTime(currentX,totalwidth,curnumber);
			}
			duc_t[curnumber].onmousedown=function(ev){
				t.durationmouseflag=true;
			}
			duc_v[curnumber].onmousemove=function(ev){
				var currentX=ev.layerX||ev.offsetX;
				if(t.durationmouseflag===true){
					var totalwidth=duc[curnumber].clientWidth;
					t.setCurrentTime(currentX,totalwidth,curnumber);					
				}
			}
		},
		//控件html创建
		getControlhtml:function(divIdObj){
			var t=this,vidoeProgressBarHtml='',controlshtml='';
			var controlheadnode=doc.createElement('div');
			controlheadnode.className='hcinit_control_head';
			//controlheadnode.className='button_big';
			divIdObj.appendChild(controlheadnode);
			//播放进度条
			var vidoeProgressBarControl=doc.createElement('div');
			vidoeProgressBarControl.className ='hcinit_video_durationcontrol';
			vidoeProgressBarHtml+='<span class="hcinit_video_durationcontrol_top"></span>';
			vidoeProgressBarHtml+='<div class="hcinit_video_durationcontrol_value">';
				vidoeProgressBarHtml+='<div class="hcinit_video_durationcontrol_current"></div>';
			vidoeProgressBarHtml+='</div>';
			vidoeProgressBarControl.innerHTML =vidoeProgressBarHtml;
			controlheadnode.appendChild(vidoeProgressBarControl);
			//控件事件处理
			var control=doc.createElement('div');
			control.className ='hcinit_video_contols';
			//controlshtml+='<div class="hcinit_video_contols_button"><input type="button" class="hcinit_video_controls_stop hcinit_video_controls_startstop" value=""></div>';
			controlshtml+='<div class="hcinit_video_contols_button"><input type="button" class="hcinit_video_controls_startstop hcinit_video_controls_start" value=""></div>';
			controlshtml+='<div class="hcinit_video_contols_button"><input type="button" class="hcinit_video_controls_reload" value=""></div>';
			
			
			controlshtml+='<div class="hcinit_video_contols_button hcinit_video_contols_duration_value"></div>';
			//大屏
			controlshtml+='<div class="hcinit_video_contols_button  fr"><input type="button" class="hcinit_video_controls_fullscreen" value=""></div>';
			//声音

			controlshtml+='<div class="hcinit_video_contols_button hcinit_video_controls_volume_button  fr">';
				controlshtml+='<input type="button" class="hcinit_video_controls_volume volume" value="">';
				controlshtml+='<div class="hcinit_video_controls_volume_bg">';
				controlshtml+='<div class="hcinit_video_controls_volume_current"></div>';
					controlshtml+='<div class="hcinit_video_controls_volume_current_top"></div>';
					controlshtml+='<div class="hcinit_video_controls_volume_value"></div>';
				controlshtml+='</div>';			
			controlshtml+='</div>';
			//倍数
			controlshtml+='<div class="hcinit_video_contols_button hcinit_video_controls_playbackRate_button fr">';
				controlshtml+='<input type="button" class="hcinit_video_controls_playbackRate" value="">';
				controlshtml+='<div class="hcinit_video_controls_playbackRate_value_select">';
					controlshtml+='<div>0.5</div><div class="hcinit_video_controls_playbackRate_value_current">1.0</div><div>1.25</div><div>1.5</div><div>2.0</div><div>2.5</div>';
				controlshtml+='</div>';
			controlshtml+='</div>';
			control.innerHTML =controlshtml;
			controlheadnode.appendChild(control);
		},
		curState:function(){//属性返回音频/视频的当前网络状态（activity）
			var statemsg;
			switch(this.videoIdObj.networkState){
				case 	0: statemsg='视频尚未初始化';break;
				case 	1: statemsg='视频是活动的且已选取资源，但并未使用网络';break;
				case 	2: statemsg='浏览器正在下载数据';break;
				case 	3: statemsg='未找到音频/视频来源';break;
				default  : statemsg='未知信息';break;
			}
			return statemsg;
		},
		//重新播放
		reLoop:function(){
			if(this.config.loop===true){
				this.videoIdObj.loop=true;
			}else{
				this.videoIdObj.loop=false;
			}
		},
		//load() 方法用于在更改来源或其他设置后对音频/视频（audio/video）元素进行更新
		reLoad:function(curnumber){
			var t=this;
			doc.getElementsByClassName('hcinit_video_controls_reload')[curnumber].onclick=function(){
				t.videoClassObj[curnumber].load();
				t.videoClassObj[curnumber].play();
				doc.getElementsByClassName('hcinit_video_controls_startstop')[curnumber].classList.add('hcinit_video_controls_stop');
				doc.getElementsByClassName('hcinit_video_controls_startstop')[curnumber].classList.remove('hcinit_video_controls_start');
			}
		},
		//play() 方法开始播放当前的音频或视频。
		startPlay:function(curnumber){
			var t=this;
			doc.getElementsByClassName('hcinit_video_controls_startstop')[curnumber].onclick=function(){
				if(t.videoClassObj[curnumber].paused===true){		
					t.videoClassObj[curnumber].play();
					doc.getElementsByClassName('hcinit_video_controls_startstop')[curnumber].classList.add('hcinit_video_controls_stop');
					doc.getElementsByClassName('hcinit_video_controls_startstop')[curnumber].classList.remove('hcinit_video_controls_start');
				}else{
				
					t.videoClassObj[curnumber].pause();
					doc.getElementsByClassName('hcinit_video_controls_startstop')[curnumber].classList.add('hcinit_video_controls_start');
					doc.getElementsByClassName('hcinit_video_controls_startstop')[curnumber].classList.remove('hcinit_video_controls_stop');
				}
			}
		},
		//pause() 方法停止（暂停）当前播放的音频或视频。
		stopPause:function(curnumber){
			var t=this;
			doc.getElementsByClassName('hcinit_video_controls_stop')[curnumber].onclick=function(){
				t.videoClassObj[curnumber].pause();
			}
		},
		getBuffered:function(){
			//获得视频的第一段缓冲范围（部分），以秒计：
			//length - 获得音频/视频中已缓冲范围的数量
			//start(index) - 获得某个已缓冲范围的开始位置
			//end(index) - 获得某个已缓冲范围的结束位置
			 alert("Start: " + this.videoIdObj.buffered.start(0) + " End: "  + this.videoIdObj.buffered.end(0));
		},
		//静音true|false
		setmuted:function(curnumber){
			var t=this;
			if(t.videoClassObj[curnumber].muted!=undefined){
				t.videoClassObj[curnumber].muted===true?t.videoClassObj[curnumber].muted=false:t.videoClassObj[curnumber].muted=true;
			}else if(t.videoIdObj.defaultMuted!=undefined){
				//只有 Chrome 和 Safari 6 支持 defaultMuted 属性。
				t.videoClassObj[curnumber].defaultMuted===true?t.videoClassObj[curnumber].defaultMuted=false:t.videoClassObj[curnumber].defaultMuted=true;
			}
		},
		getTimeToDate:function(curtime){
			var hour,hourminute,minute,second;
			hour=Math.floor(curtime/3600);
			if(hour<10){hour="0"+hour;}
			minute=Math.floor(Math.floor(curtime%3600)/60);//剩余分钟数
			if(minute<10){minute="0"+minute;}
			second=Math.floor(curtime%60);
			if(second<10){second="0"+second;}
			return hour+ ":" +minute+':'+second;
		},
		isvVdeoType:function(vidType,codType){//'video/mp4','avc1.42E01E, mp4a.40.2' ||  'video/ogg','theora, vorbis'
			var isSupp=this.videoObj.canPlayType(vidType+';codecs="'+codType+'"');
			return isSupp==""?false:true;
		},
  }
}(window)